package Main;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */


import Component.MyForm;
import Global.GlobalGameOption;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author Huy
 */
public class WaitingState extends GameState {

	public WaitingState(Game _game) {
		super(_game);
		form = new MyForm(0, 0, 0, 0);
		try {
			Global.ResourceManager.initResource(GlobalGameOption.getOption().texturePackage);
		} catch (Exception ex) {
			Logger.getLogger(WaitingState.class.getName()).log(Level.SEVERE, null, ex);
		}

	}

	@Override
	public void update(float t) {
		if (game.getHeight() > 0 && game.getWidth() > 0) {
			game.gameState = new GameMenuState(game);
		}
	}
}
